﻿@using RealtyReview.Models
@model LoginViewModel
<div class="container">
    <div class="row">
        <div class="main">
            <h4>Войдите, или @Html.ActionLink("зарегистрируйтесь", "Register", "Account", routeValues: null, htmlAttributes: new { id = "registerLink" })</h4>
            <div class="row">
                <div class="col-xs-6 col-sm-6 col-md-6">
                    <a href="#" class="btn btn-lg btn-primary btn-block">Facebook</a>
                </div>
                <div class="col-xs-6 col-sm-6 col-md-6">
                    <a href="#" class="btn btn-lg btn-info btn-block">Google</a>
                </div>
            </div>
            <div class="login-or">
                <hr class="hr-or">
                <span class="span-or">or</span>
            </div>
            <section id="loginForm">
                @using (Html.BeginForm("Login", "Account", new {ReturnUrl = ViewBag.ReturnUrl}, FormMethod.Post, new {role = "form"}))
                {
                    @Html.AntiForgeryToken()
                    @Html.ValidationSummary(true, "", new {@class = "text-danger"})
                    <div class="form-group">
                        @Html.LabelFor(m => m.Email)
                        @Html.TextBoxFor(m => m.Email, new {@class = "form-control"})
                        @Html.ValidationMessageFor(m => m.Email, "", new {@class = "text-danger"})
                    </div>
                    <div class="form-group">
                        <a class="pull-right" href="#">Забыли пароль?</a>
                        @Html.LabelFor(m => m.Password)
                        @Html.PasswordFor(m => m.Password, new {@class = "form-control"})
                        @Html.ValidationMessageFor(m => m.Password, "", new {@class = "text-danger"})
                    </div>
                    <div class="checkbox pull-right">
                        <label>
                            @Html.CheckBoxFor(m => m.RememberMe)
                            @Html.LabelFor(m => m.RememberMe)
                        </label>
                    </div>
                    <button type="submit" class="btn btn btn-primary">Войти</button>
                }
            </section>
            <section id="socialLoginForm">
                @Html.Partial("_ExternalLoginsListPartial", new ExternalLoginListViewModel { ReturnUrl = ViewBag.ReturnUrl })
            </section>
        </div>
    </div>
</div>
@section Scripts {
    <script src="@Url.Content("~/libs/jquery-validation/jquery.validate.js")"></script>
    <script src="@Url.Content("~/libs/jquery-validation-unobtrusive/jquery.validate.unobtrusive.js")"></script>
}
